/**
 * 
 */
package metalink.admin;

import java.util.ArrayList;

import model.admin.StudentFinanceMo;
import vo.StudentFinancialsVo;

import com.opensymphony.xwork2.ActionSupport;

/**
 * @author Sony
 *
 */
public class EditedSemwiseFee extends ActionSupport{
	
	int amt_paid=0,student_id,year_semester_id;
	String t_id="";
	ArrayList<StudentFinancialsVo> list = new ArrayList<StudentFinancialsVo>();
	ArrayList<StudentFinancialsVo> onetime = new ArrayList<StudentFinancialsVo>();
		public String execute() {
			

				StudentFinanceMo mo = new StudentFinanceMo();
				list = mo.getStudentFinancials(student_id);
				onetime=mo.getOneTimeFinancials(student_id);
				setStudent_id(student_id);
				try {
					System.out.println("came to editedsemwise action "+t_id+" "+amt_paid+" "+student_id);
					mo.insertSemwiseTransaction(t_id,amt_paid,student_id,year_semester_id,"InsertSemwise");
				} catch (Exception e) {
					addActionError(e.getMessage());
					return SUCCESS;
				}		
			
			return SUCCESS;
		}
		
		public int getYear_semester_id() {
			return year_semester_id;
		}

		public void setYear_semester_id(int year_semester_id) {
			this.year_semester_id = year_semester_id;
		}

		public ArrayList<StudentFinancialsVo> getList() {
			return list;
		}
		public void setList(ArrayList<StudentFinancialsVo> list) {
			this.list = list;
		}
		public ArrayList<StudentFinancialsVo> getOnetime() {
			return onetime;
		}
		public void setOnetime(ArrayList<StudentFinancialsVo> onetime) {
			this.onetime = onetime;
		}
		public int getStudent_id() {
			return student_id;
		}
		public void setStudent_id(int student_id) {
			this.student_id = student_id;
		}
		public int getAmt_paid() {
			return amt_paid;
		}
		public void setAmt_paid(int amt_paid) {
			this.amt_paid = amt_paid;
		}

		public String getT_id() {
			return t_id;
		}
		public void setT_id(String t_id) {
			this.t_id = t_id;
		}
}
